<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>功德榜</title>
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="black" />
    <meta name="format-detection" content="telephone=no, email=no" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <script type="text/javascript" src="{MODULE_URL}public/yu/js/flexible.js"></script>
    <script type="text/javascript" src="{MODULE_URL}public/yu/js/pageLoading.js"></script>
    <script type="text/javascript" src="{MODULE_URL}public/yu/js/jquery.js"></script>
    <link type="text/css" rel="stylesheet" href="{MODULE_URL}public/yu/css/index.css">

    <script src="{MODULE_URL}public/yu/js/zepto.min.js"></script>
    <link type="text/css" rel="stylesheet" href="{MODULE_URL}public/yu/css/gd.css">

</head>
<body>
<h1>已连续放生1天</h1>
<nav id='but'></nav>
<section>

    <h2><span class='org'>您尚未上榜</span></h2>

    <div class="list" id="list">
        <div id="bigbox">
            <ul id="ul">
            {loop $list $v}
                <li><h3><span class='red'>{$v['name']}</span>连续放生{$v['have']}天功德无量</h3></li>
            {/loop}
            </ul>
            <ul id="ul2"></ul>
        </div>

    </div>

</section>

<div class='box'>
    <ul id='box'>
    </ul>
</div>

<div class="bg" id="bg">
    <div class='button'>
        <p><span id="xbut">X</span></p>
        <p style="white-space: normal; font-size: 17.1429px;"><strong>唯独放生功德第一，您只要连续放生7天，</strong></p>
        <p style="white-space: normal; font-size: 17.1429px;"><strong>即可荣登功德榜，解救众生脱离苦海！</strong><br/></p>
        <p style="white-space: normal;"><strong><br/></strong></p>
        <p><br/></p>        <!--<h4>唯有放生，功德最为第一，您只要连续放生7天，就可荣登功德榜，解救众生脱离苦海！</h4>-->
        <h5 id="sure">确定</h5>
    </div>
</div>


<script type="text/javascript">
    window.onload = function(){
        //弹框
        var but=document.getElementById('but')
        var bg=document.getElementById('bg')
        but.onclick = function(){
            bg.style.display='block';
        }
        //关闭弹框
        var xbut=document.getElementById('xbut')
        var sure=document.getElementById('sure')
        xbut.onclick = function(){
            bg.style.display='none';
        }
        sure.onclick = function(){
            bg.style.display='none';
        }
        //文字上轮播
        var bigbox=document.getElementById("bigbox")
        var list=document.getElementById("list")
        var colee1=document.getElementById("ul");
        var colee2=document.getElementById("ul2");
        colee2.innerHTML=colee1.innerHTML; //克隆colee1为colee2

        if(colee1.offsetHeight<list.offsetHeight){
            colee1.style.height=list.offsetHeight+'px'
            colee2.style.height=list.offsetHeight+'px'
        } else{
            colee1.style.height=colee1.offsetHeight+'px'
        }


        //var number=list.clientHeight;
        var number=0;
        function scrollup(){
            if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) {
                number = number-3;
            }else{
                number--;
            }
            bigbox.style.transform="translateY("+number+"px)";
            bigbox.style.webkitTransform="translateY("+number+"px)";
            if(number<=-bigbox.offsetHeight/2){
                number=number+bigbox.offsetHeight/2;
            }
        }

        setInterval(scrollup,40)

        //文字左轮播
        var box=document.getElementById('box')

        var num=0;
        var a=0;
        var lil= $('#box li').length;
        box.innerHTML=box.innerHTML+box.innerHTML;
        for(i=0;i<lil/2+1;i++){
            a=a+$('#box li')[i].clientWidth;
        }
        function scroll(){
            if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) {
                num = num-3;
            }else{
                num--;
            }
            box.style.transform="translateX("+num+"px)";
            box.style.webkitTransform="translateX("+num+"px)";
            if(num<=-a){
                num=num+a;
            }
        }
        setInterval(scroll,20)

    }
</script>


<!-- 底部导航 -->
 {template 'yucommon/nav'}
<!-- 底部导航 -->
<!--<div id="mask"></div>-->

<script src="{MODULE_URL}public/yu/js/fun.js"></script>


</body>
</html>